<template>
  <div class="fullscreen">
    <i class="el-icon-full-screen" @click="fn" />
  </div>
</template>

<script>
import fullscreen from 'screenfull'
export default {
  methods: {
    fn() {
      // 处于全屏：退出全屏
      // 处于非全屏：进入全屏
      fullscreen.toggle()
    }
  }
}
</script>

<style>
.fullscreen {
}
</style>
